﻿using GalaSoft.MvvmLight.Messaging;
using KinectCurve.Entities;
using System.Windows;

namespace KinectCurve.ViewModel
{
    public partial class GameViewModel
    {
        private void StartGame()
        {
            //TODO: initialize game objects
        }

        private void AddPlayer()
        {
            playerList.Add(new Player(playerList.Count + 1));
        }

        private void RemovePlayer(Player player)
        {
            playerList.Remove(player);
        }

        private void UpdatePlayerScore(Player player, int points)
        {
            player.Score += points;
            //TODO: call an update to UI, to refresh player scores
        }

        private void EndGame(EnumGameEnd gameEnd)
        {
            switch (gameEnd)
            {
                case EnumGameEnd.Normal:
                    //show score
                    break;
                case EnumGameEnd.TimeExpired:
                    //tell players that time is expired
                    //what now? score management?
                    break;
                case EnumGameEnd.UserAborted:
                    //what now?
                    break;
                default:
                    break;
            }
        }
    }
}
